<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>kvDiag.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="kvaser.gif"/></td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('kv_diag_8h.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#nested-classes">Data Structures</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">kvDiag.h File Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>The CANtegrity API is based on high frequency sampling of the CAN bus. This allows it to be used for various purposes, such as calculating the bitrate on the bus and measuring clock speeds of devices on the bus.  
<a href="#details">More...</a></p>
<div class="textblock"><code>#include &lt;<a class="el" href="canlib_8h_source.html">canlib.h</a>&gt;</code><br />
<code>#include &lt;stdint.h&gt;</code><br />
</div>
<p><a href="kv_diag_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Data Structures</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbitrate__t.html">bitrate_t</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbitrates__t.html">bitrates_t</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structkv_diag_sample.html">kvDiagSample</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structkv_analyzer_info__t.html">kvAnalyzerInfo_t</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr><td colspan="2"><div class="groupHeader">DIAG_ANALYZER_TYPE_xxx</div></td></tr>
<tr><td colspan="2"><div class="groupText"><p>Analyzer type. <a class="anchor" id="DIAG_ANALYZER_TYPE_xxx"></a></p>
</div></td></tr>
<tr class="memitem:a29188edd320816f6f3b4e98e6b331a66"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="kv_diag_8h.html#a29188edd320816f6f3b4e98e6b331a66">DIAG_ANALYZER_TYPE_DEFAULT</a>&#160;&#160;&#160;0</td></tr>
<tr class="separator:a29188edd320816f6f3b4e98e6b331a66"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr><td colspan="2"><div class="groupHeader">DIAG_PROGRAM_TYPE</div></td></tr>
<tr><td colspan="2"><div class="groupText"><p>Possible programs that can be run on an analyzer. Used with <a class="el" href="group__kvdiag__diagnostics.html#gad615ea3768542e4d48f10d0dca4ef46d">kvDiagSetProgram()</a>. </p>
</div></td></tr>
<tr class="memitem:ad24c2e14068b790b7b105c6423e42400"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="kv_diag_8h.html#ad24c2e14068b790b7b105c6423e42400">DIAG_PROGRAM_TYPE_NORMAL</a>&#160;&#160;&#160;0</td></tr>
<tr class="separator:ad24c2e14068b790b7b105c6423e42400"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a64bb36d4e56a896eb2af5dc09cce1542"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="kv_diag_8h.html#a64bb36d4e56a896eb2af5dc09cce1542">DIAG_PROGRAM_TYPE_AUTOBAUD</a>&#160;&#160;&#160;1</td></tr>
<tr class="separator:a64bb36d4e56a896eb2af5dc09cce1542"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ga926f63f2ccb0b56ff4917151ab5e27fe"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga926f63f2ccb0b56ff4917151ab5e27fe">kvDiagGetNumberOfAnalyzers</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd, int *analyzerCount)</td></tr>
<tr class="separator:ga926f63f2ccb0b56ff4917151ab5e27fe"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga348f389077d77b8fd4cf04ad53558aad"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga348f389077d77b8fd4cf04ad53558aad">kvDiagGetAnalyzerInfo</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd, <a class="el" href="structkv_analyzer_info__t.html">kvAnalyzerInfo_t</a> *info)</td></tr>
<tr class="separator:ga348f389077d77b8fd4cf04ad53558aad"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga76d09ccb89cf756d954144582f730330"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga76d09ccb89cf756d954144582f730330">kvDiagAttachAnalyzer</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd, int type)</td></tr>
<tr class="separator:ga76d09ccb89cf756d954144582f730330"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga61263295b3feaad95c257eef05a9579b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga61263295b3feaad95c257eef05a9579b">kvDiagDetachAnalyzer</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd)</td></tr>
<tr class="separator:ga61263295b3feaad95c257eef05a9579b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad615ea3768542e4d48f10d0dca4ef46d"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#gad615ea3768542e4d48f10d0dca4ef46d">kvDiagSetProgram</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd, int programType, const char *const configBuffer)</td></tr>
<tr class="separator:gad615ea3768542e4d48f10d0dca4ef46d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga9cb62a80b9ffe4ea80b22acfb49bd3a4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga9cb62a80b9ffe4ea80b22acfb49bd3a4">kvDiagStart</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd)</td></tr>
<tr class="separator:ga9cb62a80b9ffe4ea80b22acfb49bd3a4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga685c95a3e168601a28e680d9c820dd8a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga685c95a3e168601a28e680d9c820dd8a">kvDiagStop</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd)</td></tr>
<tr class="separator:ga685c95a3e168601a28e680d9c820dd8a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga43a268ee89c38c3ac496d20f35a48105"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga43a268ee89c38c3ac496d20f35a48105">kvDiagReadSample</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd, <a class="el" href="structkv_diag_sample.html">kvDiagSample</a> *sample)</td></tr>
<tr class="separator:ga43a268ee89c38c3ac496d20f35a48105"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaab9b2bc0856a7200d1f76533092eb023"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#gaab9b2bc0856a7200d1f76533092eb023">kvDiagReadSampleWait</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd, <a class="el" href="structkv_diag_sample.html">kvDiagSample</a> *sample, int timeout)</td></tr>
<tr class="separator:gaab9b2bc0856a7200d1f76533092eb023"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gabc77cf695c7fb518263d32539a3aec9e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#gabc77cf695c7fb518263d32539a3aec9e">kvDiagCalculateBitrate</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd, <a class="el" href="structbitrates__t.html">bitrates_t</a> *btr)</td></tr>
<tr class="separator:gabc77cf695c7fb518263d32539a3aec9e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga65bbdc1e8c8bf4affc8ba2041d72ff1a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga65bbdc1e8c8bf4affc8ba2041d72ff1a">kvDiagResetBitrateCalculation</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd)</td></tr>
<tr class="separator:ga65bbdc1e8c8bf4affc8ba2041d72ff1a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga243548139dcbb64ff273648dd0c370dd"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga243548139dcbb64ff273648dd0c370dd">kvDiagCalculateClockOffset</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd, int id, double *fMin, double *fMax, double *fMean, double *fStd, int *n)</td></tr>
<tr class="separator:ga243548139dcbb64ff273648dd0c370dd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga1708e589eb731c11c82a621b2a070d1d"><td class="memItemLeft" align="right" valign="top"><a class="el" href="canstat_8h.html#a52b5e5c71832b0bd3c6a5b1fd48583e7">canStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__kvdiag__diagnostics.html#ga1708e589eb731c11c82a621b2a070d1d">kvDiagResetClockOffsetCalculation</a> (const <a class="el" href="canlib_8h.html#ae3d1b041d62207d5336f93c089cd5b65">canHandle</a> canHnd)</td></tr>
<tr class="separator:ga1708e589eb731c11c82a621b2a070d1d"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>The CANtegrity API is based on high frequency sampling of the CAN bus. This allows it to be used for various purposes, such as calculating the bitrate on the bus and measuring clock speeds of devices on the bus. </p>
<dl class="section note"><dt>Note</dt><dd>Not supported in linux!</dd></dl>
<dl class="section note"><dt>Note</dt><dd>The CANtegrity API is preliminary and will change!</dd></dl>
</div><h2 class="groupheader">Macro Definition Documentation</h2>
<a id="a29188edd320816f6f3b4e98e6b331a66"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a29188edd320816f6f3b4e98e6b331a66">&#9670;&nbsp;</a></span>DIAG_ANALYZER_TYPE_DEFAULT</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define DIAG_ANALYZER_TYPE_DEFAULT&#160;&#160;&#160;0</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Default. </p>

</div>
</div>
<a id="a64bb36d4e56a896eb2af5dc09cce1542"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a64bb36d4e56a896eb2af5dc09cce1542">&#9670;&nbsp;</a></span>DIAG_PROGRAM_TYPE_AUTOBAUD</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define DIAG_PROGRAM_TYPE_AUTOBAUD&#160;&#160;&#160;1</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a id="ad24c2e14068b790b7b105c6423e42400"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad24c2e14068b790b7b105c6423e42400">&#9670;&nbsp;</a></span>DIAG_PROGRAM_TYPE_NORMAL</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define DIAG_PROGRAM_TYPE_NORMAL&#160;&#160;&#160;0</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- HTML footer for doxygen 1.8.13-->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_8af83c0dc83a45a35ca6968cdc29a7af.html">tmp</a></li><li class="navelem"><a class="el" href="dir_b077c42d920d220d4fe5af62a68f598c.html">src</a></li><li class="navelem"><a class="el" href="kv_diag_8h.html">kvDiag.h</a></li>
    <li class="footer"> (canlib 5.38) Tue Feb 15 2022</li>
  </ul>
</div>
</body>
</html>
